home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 January: Mac OS SDK / Dev.CD Jan 97 SDK2.toast / Development Kits (Disc 2) / OpenDoc Development Framework / ODF-Interest Archive / June 96 / Requesting a new frame shape < prev    next >
Encoding:
Internet Message Format  |  1996-12-03  |  1.1 KB  |  [TEXT/ttxt]

  1. Subject:     Requesting a new frame shape
  2. Sent:        6/11/96 11:32 AM
  3. Received:    6/11/96 11:41 AM
  4. From:        Neal Williams, neal@corda.com
  5. Reply-To:    ODF Interest, ODF-Interest@CILabs.ORG
  6. To:          OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
  7.  
  8. I am requesting a new frame shape for my frame, but it's not working right.
  9.  
  10. Here is the code I use:
  11.  
  12. ODShape* TheShapeIWant = MyODFrame->CreateShape(ev);
  13. TheShapeIWant->SetRectangle(ev, &MyODRect);
  14. ODShape* MyNewShape = MyODFrame->RequestFrameShape(ev, TheShapeIWant,
  15. kODNULL);
  16. MyODFrame->Invalidate(ev, kODNULL, kODNULL);
  17. MyODFrame->ChangeUsedShape(ev, kODNULL, kODNULL);    
  18. MyODFrame->InvalidateActiveBorder(ev);
  19. MyNewShape->Release(ev);
  20. TheShapeIWant->Release(ev);
  21.  
  22. After executing this code my active border changes to be the size of my
  23. frame shape, but the clip-shape and active-shape of my facet don't appear
  24. to be updating correctly. Afterwards, If I click in the undisplayed portion
  25. of my frame I get a one-way trip to the debugger.
  26.  
  27. BTW, I'm embeded within ODF Draw.
  28.  
  29. I used this same code in my non-ODF OpenDoc part and everything worked
  30. fine.
  31.  
  32. -Neal
  33.